package org.andao.core.dao.hibernate;

import org.hibernate.SessionFactory;
import org.springframework.beans.factory.annotation.Autowired;

/**
 * 基础的hibernate支持Dao.<p>
 * 用于对Service层的Dao支持.
 *  
 * @author Seewo software - Marco.hu(huzhiguo@cvte.cn)
 */
public class BaseHibernateSupportDao{
	
	public DefaultHibernateSupportDao exGeneralHibernateDao;
		
	/**
	 * 将session factory 传给<code>ExGeneralHibernateDao</code>并创建dao实例
	 * @param sessionFactory
	 */
	@Autowired	
	public void setSessionFactory(SessionFactory sessionFactory) {
		exGeneralHibernateDao = new DefaultHibernateSupportDao(sessionFactory);		
	}
		
}
